
{{ define "admin/focus/index.html" }}
{{ template "admin/public/page_header.html" .}}
           

    <div class="table-responsive">
        <table class="table table-bordered">
            <thead>
                <tr class="th">
                    <th>轮播图名称</th>
                    <th>轮播图类型</th>
                    <th>轮播图图片</th>
                    <th>跳转地址</th>
                    <th class="text-center">排序</th>
                    <th class="text-center">状态</th>
                    <th class="text-center">操作</th>
                </tr>
            </thead>
            <tbody>
            {{range $key,$value := .focusList}}
            <tr>
                <td>{{$value.Title}}</td>
                <td>
                    {{if eq $value.FocusType 1}}                    
                    网站
                    {{else if eq $value.FocusType 2}}
                    APP
                    {{else}}
                    小程序
                    {{end}}

                </td>
                <td>
                    {{if ne $value.FocusImg ""}}
                        <img src="/{{$value.FocusImg}}" width="200"  />
                    {{end}}
                </td>
                <td>{{$value.Link}}</td>
                <td class="text-center">
                    {{$value.Sort}}
                </td>
                <td align="center">
                    {{if eq $value.Status 1}}
                    <img src="/static/admin/images/yes.gif" />
                    {{else}}
                    <img src="/static/admin/images/no.gif" />
                    {{end}}
                </td>
                <td class="text-center">
                    <a href="/admin/focus/edit?id={{$value.Id}}" />修改</a>
                    <a class="delete" href="/admin/focus/delete?id={{$value.Id}}" />删除</a>
                </td>
            </tr>
            {{end}}

            </tbody>
        </table>
    </div>

</body>
</html>

{{end}}